<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>youku数据后台</title>
<link rel="stylesheet" href="{{ static_url('templates/resources/css/reset.css') }}" type="text/css" media="screen" />
<link rel="stylesheet" href="{{ static_url('templates/resources/css/style.css') }}" type="text/css" media="screen" />
<link rel="stylesheet" href="{{ static_url('templates/resources/css/invalid.css') }}" type="text/css" media="screen" />	
<style>
.shadow{-moz-box-shadow:1px 1px 3px rgba(0,0,0,.4); -webkit-box-shadow:1px 1px 3px rgba(0,0,0,.4); box-shadow:1px 1px 3px rgba(0,0,0,.4);}
.target_box{width:auto; padding:10px; border:1px solid #aaa; background-color:#fff;}
.target_list{padding:4px; border-bottom:1px dotted #ddd; overflow:hidden; _zoom:1;}
.target_list a{width:auto; line-height:20px; margin-right:5px; padding:1px; color:#333; font-size:12px; text-align:center; text-decoration:none; float:left;}
.target_list a:hover{padding:0; border:1px solid #ddd; color:#cd0000;}
.target_more{margin-top:-20px;}

.target_fixed{height:auto; padding:1px; position:fixed; _position:absolute; top:0; right:0;}
.custom_container{position:absolute; background-color:rgba(0, 0, 0, .5); background-color:#999\9;}
.custom_container img{padding:0; position:relative; top:-5px; left:-5px;}
</style>
<script type="text/javascript" src="{{ static_url('templates/resources/scripts/jquery-1.3.2.min.js') }}"></script>
<script type="text/javascript" src="{{ static_url('templates/resources/scripts/My97DatePicker/WdatePicker.js') }}"></script>
<script type="text/javascript" src="{{ static_url('templates/resources/scripts/simpla.jquery.configuration.js') }}"></script>
<script type="text/javascript" src="{{ static_url('templates/resources/scripts/facebox.js') }}"></script>
<script type="text/javascript" src="{{ static_url('templates/resources/scripts/jquery.wysiwyg.js') }}"></script>
<script type="text/javascript" src="{{ static_url('templates/resources/scripts/jquery.datePicker.js') }}"></script>
<script type="text/javascript" src="{{ static_url('templates/resources/scripts/jquery.date.js') }}"></script>
<script type="text/javascript" src="{{ static_url('templates/resources/scripts/jquery-powerFloat.js') }}"></script>
<script>
$(function() {
	//通过默认rel属性加载
	$(".trigger").powerFloat();
	
});
</script>
<script>
    
   function pixiu() {

           var positions = '';
           var ltype = '{{ ltype }}';
        $.each($('input[name=shareuser[]]:checked') ,function(i,item){
        positions+=$(item).val()+',';
      })
      if(positions){
        positions = positions.substring(0,positions.length-1)
      }
      if(positions==''){
      alert('请选择一下！');
      }else{


           
          if (window.confirm('确实要清零吗？'))
	 { 
           $.ajax({
		type: "POST",
		url: "/pixiu",
		data : {
    pid : positions,
    ltype : ltype,
},
        dataType: "html", 
		success: function(msg){
		if(msg=='ok'){
        window.location.reload();
        }else{
         alert('失败');
        }
								}
				});
                
            }
                
                
      

      }



        
        
        
        }
       
      </script>
</head>
	<body><div id="body-wrapper"> <!-- Wrapper for the radial gradient background -->
		
		<div id="sidebar"><div id="sidebar-wrapper"> <!-- Sidebar with logo and menu -->
			
			<h1 id="sidebar-title"><a href="#">Simpla Admin</a></h1>
		  
			<!-- Logo (221px wide) -->
			<a href="#"><img id="logo" src="{{ static_url('templates/resources/images/logo.png') }}" alt="Simpla Admin logo" /></a>
		  
			<!-- Sidebar Profile links -->
			<div id="profile-links">
				Hello, <a href="#" title="Edit your profile">admin</a><br />
				<br />
				<a href="/logout" title="Sign Out">登出</a>
			</div>        
			
			<ul id="main-nav">  <!-- Accordion Menu -->

                   {% include nav.html %}
				
				
				
				
			</ul> <!-- End #main-nav -->
			
			<div id="messages" style="display: none"> <!-- Messages are shown when a link with these attributes are clicked: href="#messages" rel="modal"  -->
				
				<h3>3 Messages</h3>
			 
				<p>
					<strong>17th May 2009</strong> by Admin<br />
					Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus magna. Cras in mi at felis aliquet congue.
					<small><a href="#" class="remove-link" title="Remove message">Remove</a></small>
				</p>
			 
				<p>
					<strong>2nd May 2009</strong> by Jane Doe<br />
					Ut a est eget ligula molestie gravida. Curabitur massa. Donec eleifend, libero at sagittis mollis, tellus est malesuada tellus, at luctus turpis elit sit amet quam. Vivamus pretium ornare est.
					<small><a href="#" class="remove-link" title="Remove message">Remove</a></small>
				</p>
			 
				<p>
					<strong>25th April 2009</strong> by Admin<br />
					Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus magna. Cras in mi at felis aliquet congue.
					<small><a href="#" class="remove-link" title="Remove message">Remove</a></small>
				</p>
				
				<form action="#" method="post">
					
					<h4>New Message</h4>
					
					<fieldset>
						<textarea class="textarea" name="textfield" cols="79" rows="5"></textarea>
					</fieldset>
					
					<fieldset>
					
						<select name="dropdown" class="small-input">
							<option value="option1">Send to...</option>
							<option value="option2">Everyone</option>
							<option value="option3">Admin</option>
							<option value="option4">Jane Doe</option>
						</select>
						
						<input class="button" type="submit" value="Send" />
						
					</fieldset>
					
				</form>
				
			</div> <!-- End #messages -->
			
		</div></div> <!-- End #sidebar -->
		
		<div id="main-content"> <!-- Main Content Section with everything -->
			
			<noscript> <!-- Show a notification if the user has disabled javascript -->
				<div class="notification error png_bg">
					<div>
						Javascript is disabled or is not supported by your browser. Please <a href="http://browsehappy.com/" title="Upgrade to a better browser">upgrade</a> your browser or <a href="http://www.google.com/support/bin/answer.py?answer=23852" title="Enable Javascript in your browser">enable</a> Javascript to navigate the interface properly.
					</div>
				</div>
			</noscript>
			
			<!-- Page Head -->
			
			
			<div class="clear"></div> <!-- End .clear -->
			<form action="/" method="GET">
			开始日期:<input style="width:100px;" class="Wdate" name="div3" value="{{ div3 }}" id="div3" type="text" onfocus="WdatePicker()"  />-结束日期:<input style="width:100px;" class="Wdate" id="div4" value="{{ div4 }}" type="text" name="div4" onfocus="WdatePicker()" />&nbsp;&nbsp;PID:<input style="width:100px;" type="text" value="{{ pid }}" name="pid" id="pid" />&nbsp;&nbsp;分类:
			<select id="ltype" name="ltype">				
				<option {% if ltype == '1' %} selected=selected {% end %}   value="1">Android-Pad</option>
				<option {% if ltype == '2' %} selected=selected {% end %}  value="2">Android-Phone</option>
				<option {% if ltype == '3' %} selected=selected {% end %}  value="3">Ios-Pad</option>
				<option {% if ltype == '4' %} selected=selected {% end %}  value="4">Ios-Phone</option>
				<option {% if ltype == '5' %} selected=selected {% end %}  value="5">Wp7</option>
				<option {% if ltype == '6' %} selected=selected {% end %}  value="6">Paike-Android</option>
				<option {% if ltype == '7' %} selected=selected {% end %}  value="7">Paike-Ios</option>
			</select>&nbsp;<input type="submit" value="更新"  /> <input type="button" value="批量清零" onclick="pixiu();"  />
			<br /><br />
			</form>

			<div class="content-box"><!-- Start Content Box -->
				
				<div class="content-box-header">
					
					<h3>内容列表</h3>
					
					<!--<ul class="content-box-tabs">
						<li><a href="#tab1" class="default-tab">Table</a></li> <!-- href must be unique and match the id of target div 
						<li><a href="#tab2">Forms</a></li>
					</ul>-->
					
					<div class="clear"></div>
					
				</div> <!-- End .content-box-header -->
				
				<div class="content-box-content">
					
					<div class="tab-content default-tab" id="tab1"> <!-- This is the target div. id must match the href of this div's tab -->
						
						<!--<div class="notification attention png_bg">
							<a href="#" class="close"><img src="{{ static_url('templates/resources/images/icons/cross_grey_small.png') }}" title="Close this notification" alt="close" /></a>
							<div>
								This is a Content Box. You can put whatever you want in it. By the way, you can close this notification with the top-right cross.
							</div>
						</div>-->
						
						<table>
							
							<thead>
								<tr>
								   <th><input class="check-all" type="checkbox" /></th>
								   <th>pid</th>
                                   <th>pv</th>
                                   <th>uv</th>
                                   <th>vv</th>
                                   <th>newuser</th>
                                   <th>register</th>
								   <th>日期</th>
								   <th>操作</th>
								</tr>
								
							</thead>
						 
							<tfoot>
								<tr>
									<td colspan="6">
									
										
										<div class="pagination">
											<a href="/?page={{page['first']}}&ltype={{ ltype }}&div3={{ div3 }}&div4={{ div4 }}&pid={{ pid }}">首页</a>
<a href="/?page={{page['previous']}}&ltype={{ ltype }}&div3={{ div3 }}&div4={{ div4 }}&pid={{ pid }}">上一页</a>
<a href="/?page={{page['next']}}&ltype={{ ltype }}&div3={{ div3 }}&div4={{ div4 }}&pid={{ pid }}">下一页</a>
<a href="/?page={{page['last']}}&ltype={{ ltype }}&div3={{ div3 }}&div4={{ div4 }}&pid={{ pid }}">尾页</a>
										</div> <!-- End .pagination -->
										<div class="clear"></div>
									</td>
								</tr>
							</tfoot>
						 
							<tbody>
								
								
								{% for item in entries %}
                                <form id="f{{ item['pid'] }}{{ item['date'] }}" action="/setdanz" method="POST" >
								<tr>
									<td><input type="checkbox" name='shareuser[]' value="{{ item['pid'] }}+{{ item['date'] }}" /></td>
									<td>
                                        
                                <a class="trigger" href="javascript:;" rel="targetBox{{ item['pid'] }}{{ item['date'] }}" >{{ item['pid'] }}</a>
                                
                                <div id="targetBox{{ item['pid'] }}{{ item['date'] }}" style="display:none;" class="shadow target_box dn">
                                         pv:{{ item['pv'] }}&nbsp;uv:{{ item['uv'] }}&nbsp;vv:{{ item['vv'] }}&nbsp;newuser:{{ item['newuser'] }}&nbsp;register:{{ item['register'] }}&nbsp;<br />alluser:{{ item['alluser'] }}&nbsp;ver:{{ item['ver'] }}&nbsp;operator:{{ item['operator'] }}&nbsp;network:{{ item['network'] }}&nbsp;operator:{{ item['operator'] }}&nbsp;<br />business_type:{{ item['business_type'] }}&nbsp;device_type:{{ item['device_type'] }}&nbsp;f_id:{{ item['f_id'] }}&nbsp;os_id:{{ item['os_id'] }}&nbsp;client_type:{{ item['client_type'] }}<br />&nbsp;partner_mode:{{ item['partner_mode'] }}&nbsp;pid_stat:{{ item['pid_stat'] }}
                                    </div>
                                    
                                    
                                    </td>
                                    <td><input name="pv" style="width:40px;overflow:hidden" type="text" value="{{ item['pv'] }}" /></td>
                                    <td><input name="uv" id="uv{{ item['pid'] }}" style="width:40px;overflow:hidden" type="text" value="{{ item['uv'] }}" /></td>
                                    <td><input name="vv" id="vv{{ item['pid'] }}" style="width:40px;overflow:hidden" type="text" value="{{ item['vv'] }}" /></td>
                                    <td><input name="newuser" id="newuser{{ item['pid'] }}" style="width:40px;overflow:hidden" type="text" value="{{ item['newuser'] }}" /></td>
                                    <td><input name="register" id="register{{ item['pid'] }}" style="width:40px;overflow:hidden" type="text" value="{{ item['register'] }}" /></td>
									<td>{{ item['date'] }}</td>
									<input type="hidden" name="pid"  value="{{ item['pid'] }}" />
                                    <input type="hidden" name="date" value="{{ item['date'] }}" />
                                    <input type="hidden" name="ltype" value="{{ ltype }}" />
                                    <input type="hidden" name="tourl" value="/?page={{ _page }}&ltype={{ ltype }}&div3={{ div3 }}&div4={{ div4 }}&pid={{ pid }}" />
									<td>
										<!-- Icons -->
									<input type="button" value="修改" onclick="JavaScript:if (window.confirm('确实要修改吗？')){this.form.submit();}" />
                                    </form>
									</td>
								</tr>
								{% end %}
								
								
								
	
				
					
							</tbody>
							
						</table>
						
					</div> <!-- End #tab1 -->
					
					<div class="tab-content" id="tab2">
					
						<form action="#" method="post">
							
							<fieldset> <!-- Set class to "column-left" or "column-right" on fieldsets to divide the form into columns -->
								
								<p>
									<label>Small form input</label>
										<input class="text-input small-input" type="text" id="small-input" name="small-input" /> <span class="input-notification success png_bg">Successful message</span> <!-- Classes for input-notification: success, error, information, attention -->
										<br /><small>A small description of the field</small>
								</p>
								
								<p>
									<label>Medium form input</label>
									<input class="text-input medium-input datepicker" type="text" id="medium-input" name="medium-input" /> <span class="input-notification error png_bg">Error message</span>
								</p>
								
								<p>
									<label>Large form input</label>
									<input class="text-input large-input" type="text" id="large-input" name="large-input" />
								</p>
								
								<p>
									<label>Checkboxes</label>
									<input type="checkbox" name="checkbox1" /> This is a checkbox <input type="checkbox" name="checkbox2" /> And this is another checkbox
								</p>
								
								<p>
									<label>Radio buttons</label>
									<input type="radio" name="radio1" /> This is a radio button<br />
									<input type="radio" name="radio2" /> This is another radio button
								</p>
								
								<p>
									<label>This is a drop down list</label>              
									<select name="dropdown" class="small-input">
										<option value="option1">Option 1</option>
										<option value="option2">Option 2</option>
										<option value="option3">Option 3</option>
										<option value="option4">Option 4</option>
									</select> 
								</p>
								
								<p>
									<label>Textarea with WYSIWYG</label>
									<textarea class="text-input textarea wysiwyg" id="textarea" name="textfield" cols="79" rows="15"></textarea>
								</p>
								
								<p>
									<input class="button" type="submit" value="Submit" />
								</p>
								
							</fieldset>
							
							<div class="clear"></div><!-- End .clear -->
							
						</form>
						
					</div> <!-- End #tab2 -->        
					
				</div> <!-- End .content-box-content -->
				
			</div> <!-- End .content-box -->
			
		
			
			
			<div class="clear"></div>
			
			
			
			
			<div id="footer">
				<small> <!-- Remove this notice or replace it with whatever you want -->
						&#169; Copyright 2012 Youku.com  <a href="#">Top</a>
				</small>
			</div><!-- End #footer -->
			
		</div> <!-- End #main-content -->
	</div></body>
</html>
